﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="overview.aspx.cs" Inherits="Com.Rivyer.Web.personal.overview" %>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title>用户信息一览</title>
    <link href="../css/style.css" rel="stylesheet" type="text/css" />
    <style type="text/css">
        body
        {
            margin-left: 3px;
            margin-right: 3px;
        }
    </style>
</head>
<body>
    <%if (DesignMode)
      { %>
    <script type="text/javascript" src="../js/ASPxScriptIntelliSense.js"></script>
    <%} %>
    <script type="text/javascript">
        
    </script>
    <form id="form1" runat="server">
    <div>
        <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
            <tr>
                <td height="30">
                    <table width="100%" border="0" cellspacing="0" cellpadding="0">
                        <tr>
                            <td height="24" bgcolor="#353c44">
                                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                                    <tr>
                                        <td>
                                            <table width="100%" border="0" cellspacing="0" cellpadding="0">
                                                <tr>
                                                    <td width="6%" height="19" valign="bottom">
                                                        <div align="center">
                                                            <img src="../images/tb.gif" width="14" height="14" /></div>
                                                    </td>
                                                    <td width="94%" valign="bottom">
                                                        <span class="STYLE1">个人信息</span>
                                                    </td>
                                                </tr>
                                            </table>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
            <tr>
                <td align="center" style="font-size: 12px">
                    <table cellpadding="0" cellspacing="15px" style="width: 800px;">
                        <tr>
                            <td class="firstblock" valign="top" align="center">
                                <table border="0" cellpadding="10px" cellspacing="0" style="border: 1px solid #87adbf;
                                    width: 291px; height: 250px; vertical-align: top; text-align: center">
                                    <tr>
                                        <th colspan="2" align="left">
                                            用户信息
                                        </th>
                                    </tr>
                                    <tr>
                                        <td class="style2">
                                            <dx:ASPxLabel ID="ASPxLabel1" runat="server" Text="用户名:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxLabel ID="username" runat="server" Text="">
                                            </dx:ASPxLabel>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="style2">
                                            <dx:ASPxLabel ID="ASPxLabel2" runat="server" Text="注册时间:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxLabel ID="createdate" runat="server" Text="">
                                            </dx:ASPxLabel>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="style2">
                                            <dx:ASPxLabel ID="ASPxLabel3" runat="server" Text="登录次数:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxLabel ID="logincount" runat="server" Text="">
                                            </dx:ASPxLabel>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="style2">
                                            <dx:ASPxLabel ID="ASPxLabel4" runat="server" Text="最近一次登录:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxLabel ID="latestlogin" runat="server" Text="">
                                            </dx:ASPxLabel>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td class="style2">
                                            <dx:ASPxLabel ID="ASPxLabel5" runat="server" Text="最近一次操作:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxLabel ID="latestoperate" runat="server" Text="">
                                            </dx:ASPxLabel>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                            <td class="secondblock" rowspan="2" valign="top" align="center">
                                <dx:ASPxGridView ID="infogrid" runat="server" Width="450px" Border-BorderColor="#87adbf"
                                    Styles-Cell-HorizontalAlign="Center" AutoGenerateColumns="False" DataSourceID="userloginds"
                                    Font-Size="12px">
                                    <Columns>
                                        <dx:GridViewDataTextColumn FieldName="loginip" VisibleIndex="3" Caption="IP">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataDateColumn FieldName="logintime" VisibleIndex="2" Width="120px" Caption="登录时间">
                                            <PropertiesDateEdit DisplayFormatString="MM/dd hh:mm:ss">
                                            </PropertiesDateEdit>
                                        </dx:GridViewDataDateColumn>
                                    </Columns>
                                    <SettingsPager PageSize="6">
                                    </SettingsPager>
                                    <Settings ShowFilterRow="True" />
                                    <Styles EnableDefaultAppearance="true">
                                        <Header HorizontalAlign="Center">
                                        </Header>
                                        <Cell HorizontalAlign="Center">
                                        </Cell>
                                    </Styles>
                                    <Border BorderColor="#87ADBF" BorderStyle="Solid" BorderWidth="1px" />
                                </dx:ASPxGridView>
                                <asp:SqlDataSource ID="userloginds" runat="server" ConnectionString="<%$ ConnectionStrings:ITConnectionString %>"
                                    ProviderName="System.Data.SqlClient" SelectCommand="SELECT [username], [loginip], [logintime] FROM [tb_userloginlog] WHERE ([username] = @username) ORDER BY [logintime] DESC">
                                    <SelectParameters>
                                        <asp:SessionParameter Name="username" SessionField="username" Type="String" />
                                    </SelectParameters>
                                </asp:SqlDataSource>
                                <asp:SqlDataSource ID="latestloginandoperate" runat="server" ConnectionString="<%$ ConnectionStrings:ITConnectionString %>"
                                    ProviderName="System.Data.SqlClient" SelectCommand="SELECT [username], [operation], [description], [createdate] FROM [tb_useroperatelog] WHERE ([username] = @username) ORDER BY [createdate] DESC">
                                    <SelectParameters>
                                        <asp:SessionParameter Name="username" SessionField="username" Type="String" />
                                    </SelectParameters>
                                </asp:SqlDataSource>
                                <br />
                                <dx:ASPxGridView ID="latestlogingrid" runat="server" Width="450px" Border-BorderColor="#87adbf"
                                    Styles-Cell-HorizontalAlign="Center" AutoGenerateColumns="False" DataSourceID="latestloginandoperate"
                                    Font-Size="12px">
                                    <Columns>
                                        <dx:GridViewDataTextColumn FieldName="operation" VisibleIndex="3" Width="30px" Caption="操作">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn FieldName="description" VisibleIndex="4" Caption="描述" Width="180px">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataDateColumn FieldName="createdate" VisibleIndex="2" Width="90px"
                                            Caption="时间">
                                            <PropertiesDateEdit DisplayFormatString="MM/dd hh:mm:ss">
                                            </PropertiesDateEdit>
                                        </dx:GridViewDataDateColumn>
                                    </Columns>
                                    <SettingsPager ShowDefaultImages="False">
                                    </SettingsPager>
                                    <Styles EnableDefaultAppearance="true">
                                        <Header HorizontalAlign="Center">
                                        </Header>
                                        <Cell HorizontalAlign="Center">
                                        </Cell>
                                    </Styles>
                                    <Border BorderColor="#87ADBF" BorderStyle="Solid" BorderWidth="1px" />
                                </dx:ASPxGridView>
                            </td>
                        </tr>
                        <tr>
                            <td class="thirdblcok" valign="top" align="center">
                                <hr />
                                <table border="0" cellpadding="10px" cellspacing="0" style="border: 1px solid #87adbf;
                                    width: 291px; height: 250px; vertical-align: top; text-align: center">
                                    <tr>
                                        <td>
                                            <dx:ASPxLabel ID="ASPxLabel6" runat="server" Text="真实姓名:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td align="left">
                                            <dx:ASPxLabel ID="realname" runat="server" Text="" Width="150px">
                                            </dx:ASPxLabel>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <dx:ASPxLabel ID="ASPxLabel7" runat="server" Text="年龄:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxSpinEdit ID="age" runat="server" Height="21px" Number="0" ClientInstanceName="ageclient"
                                                MinValue="20" MaxValue="100" Width="150px" NullText="请输入年龄!">
                                            </dx:ASPxSpinEdit>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <dx:ASPxLabel ID="ASPxLabel8" runat="server" Text="家庭住址:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxTextBox ID="homeadress" runat="server" Width="150px" NullText="请输入家庭住址!">
                                                <ValidationSettings ErrorText="家庭住址不正确!" ErrorDisplayMode="ImageWithTooltip" Display="Dynamic">
                                                    <RequiredField ErrorText="不能为空!" IsRequired="true" />
                                                </ValidationSettings>
                                            </dx:ASPxTextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <dx:ASPxLabel ID="ASPxLabel9" runat="server" Text="手机号码:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxTextBox ID="telephone" runat="server" Width="150px" NullText="请输入手机号码!">
                                                <ValidationSettings ErrorText="手机号码不正确!" ErrorDisplayMode="ImageWithTooltip" Display="Dynamic">
                                                    <RequiredField ErrorText="不能为空!" IsRequired="true" />
                                                    <RegularExpression ErrorText="必须为11位数字!" ValidationExpression="^[0-9]+$" />
                                                </ValidationSettings>
                                            </dx:ASPxTextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            <dx:ASPxLabel ID="ASPxLabel10" runat="server" Text="QQ号:">
                                            </dx:ASPxLabel>
                                        </td>
                                        <td>
                                            <dx:ASPxTextBox ID="qqnum" runat="server" Width="150px" NullText="请输入QQ号码!" ClientInstanceName="qqnumclient">
                                                <ValidationSettings ErrorText="QQ号码不正确!" ErrorDisplayMode="ImageWithTooltip" Display="Dynamic">
                                                    <RequiredField ErrorText="不能为空!" IsRequired="true" />
                                                    <RegularExpression ErrorText="格式不正确!必须从10000开始!" ValidationExpression="[1-9][0-9]{4,}" />
                                                </ValidationSettings>
                                            </dx:ASPxTextBox>
                                        </td>
                                    </tr>
                                    <tr>
                                        <td colspan="2" align="center">
                                            <dx:ASPxButton ID="btn_edit" runat="server" Text="保存" OnClick="btn_edit_Click">
                                            </dx:ASPxButton>
                                        </td>
                                    </tr>
                                </table>
                            </td>
                        </tr>
                    </table>
                </td>
            </tr>
        </table>
    </div>
    </form>
</body>
</html>
